package com.ra.crm;

import java.io.File;
import java.math.BigDecimal;
import java.util.Date;

import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Transient;

import com.googlecode.cswish.annotation.cm;

@Entity
@cm("业主申请")
public class ProprietaryReq {
	
	private Integer id;
	
	@cm("房东")
	public final static Integer REQ_TYPE_LANDLORD = 1;
	@cm("品牌")
	public final static Integer REQ_TYPE_BRAND = 2;
	@cm("供应商")
	public final static Integer REQ_TYPE_SUPPLY = 3;
	
	@cm("毛坯房")
	public final static Integer FITMENT_TYPE_NAKED = 1;
	@cm("已装修")
	public final static Integer FITMENT_TYPE_FINISHED = 2;
	
	@cm("申请类型")
	private Integer reqType;

	@cm("房源地址")
	private String address;
	
	@cm("户型")
	private Integer roomType;
	
	@cm("面积")
	private BigDecimal area;
	
	@cm("签约年数")
	private Integer signYear;
	
	@cm("房屋类型")
	private Integer fitmentType;
	
	@cm("是否容许改造")
	private Boolean refactor;
	
	// transient
	@cm("户型图")
	private File attachment;
	
	// transient
	private String attachmentContentType;
	
	private String attachmentFileName;
	
	@cm("联系人")
	private String contact;
	
	@cm("手机号码")
	private String phone;
	
	@cm("联系地址")
	private String contactAddress;
	
	@cm("其它要求")
	private String requirement;
	
	@cm("创建时间")
	private Date createDate;

	@Id
	@GeneratedValue
	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}
	
	public Integer getReqType() {
		return reqType;
	}

	public void setReqType(Integer reqType) {
		this.reqType = reqType;
	}

	public String getAddress() {
		return address;
	}

	public void setAddress(String address) {
		this.address = address;
	}

	public Integer getRoomType() {
		return roomType;
	}

	public void setRoomType(Integer roomType) {
		this.roomType = roomType;
	}

	public BigDecimal getArea() {
		return area;
	}

	public void setArea(BigDecimal area) {
		this.area = area;
	}

	public Integer getSignYear() {
		return signYear;
	}

	public void setSignYear(Integer signYear) {
		this.signYear = signYear;
	}

	public Integer getFitmentType() {
		return fitmentType;
	}

	public void setFitmentType(Integer fitmentType) {
		this.fitmentType = fitmentType;
	}

	public Boolean getRefactor() {
		return refactor;
	}

	public void setRefactor(Boolean refactor) {
		this.refactor = refactor;
	}

	@Transient
	public File getAttachment() {
		return attachment;
	}

	public void setAttachment(File attachment) {
		this.attachment = attachment;
	}

	public String getAttachmentContentType() {
		return attachmentContentType;
	}

	public void setAttachmentContentType(String attachmentContentType) {
		this.attachmentContentType = attachmentContentType;
	}

	public String getAttachmentFileName() {
		return attachmentFileName;
	}

	public void setAttachmentFileName(String attachmentFileName) {
		this.attachmentFileName = attachmentFileName;
	}

	public String getContact() {
		return contact;
	}

	public void setContact(String contact) {
		this.contact = contact;
	}

	public String getPhone() {
		return phone;
	}

	public void setPhone(String phone) {
		this.phone = phone;
	}

	public String getContactAddress() {
		return contactAddress;
	}

	public void setContactAddress(String contactAddress) {
		this.contactAddress = contactAddress;
	}

	public String getRequirement() {
		return requirement;
	}

	public void setRequirement(String requirement) {
		this.requirement = requirement;
	}

	public Date getCreateDate() {
		return createDate;
	}

	public void setCreateDate(Date createDate) {
		this.createDate = createDate;
	}
}
